#ifndef MENU_ITEM_H_
#define MENU_ITEM_H_

#include <string>

// other types
#include "Description.h"				//uncomment once you have added the type definition
using namespace std;

struct Menu_Item
{
public:
	// constructors
	Menu_Item(){}
	Menu_Item (int id, int cat, int rec, string n, double amt, Description s)	//uncomment once you have added the type definition
		: menu_item_id(id), cat_id(cat), recipe_id(rec), menu_item_name(n), price(amt), descr(s) {}

	friend std::istream& operator>> (std::istream& in, Menu_Item& mi) { 
       return (in >> mi.menu_item_id >> mi.cat_id >> mi.recipe_id >> mi.menu_item_name >> mi.price >> mi.descr); 
    }
    friend std::ostream& operator<< (std::ostream& os, Menu_Item const& mi) { 
       return os << mi.menu_item_id << " " << mi.cat_id << " " << mi.recipe_id << " " << mi.menu_item_name << " " << mi.price << " " << mi.descr;
    }

   // utility functions
	string display() const;
	
	int get_recipe_id()//AJN B1
	{
		return recipe_id;
	}
	string get_name()//AJN B1
	{
		return menu_item_name;
	}
	string get_description_string()//AJN B1
	{
		return descr.getDescText();
	}
	double get_price()//AJN B1
	{
		return price;
	}
	int get_cat_id()//AJN B1
	{
		return cat_id;
	}
	int get_menu_item_id(){return menu_item_id;}//JTL B2.a
	
	//Getters Ecky B3
        int getId()                     { return menu_item_id; }
        int getCategId()        { return cat_id; }
        int getRecipeId()       { return recipe_id; }
	

private:
   //constants
     
   // private data
	int menu_item_id;
	int cat_id;
	int recipe_id;
	string menu_item_name;
	double price;
	Description descr;			//uncomment once you have added the type definition
   
};


#endif //MENU_ITEM_H_
